//
//  JWScreenHelper.m
//  JWBrowser
//
//  Created by Dejun Liu on 14-12-4.
//  Copyright (c) 2014年 JW. All rights reserved.
//

#import "JWScreenHelper.h"

@implementation JWScreenHelper

+ (float) ScreenHeight
{
    if(IOS_8_OR_LATER)
    {
        return SCREEN_HEIGHT;
    }else if(IOSVersionLessThan(8.0f))
    {
        if(DEVICE_IS_PORTRAIT)
        {
            return SCREEN_HEIGHT;
        }else
        {
            return SCREEN_WIDTH;
        }
    }
    return 0;
}

+ (float) ScreenWidth
{
    if(IOS_8_OR_LATER)
    {
        return SCREEN_WIDTH;
    }else if(IOSVersionLessThan(8.0f))
    {
        if(DEVICE_IS_PORTRAIT)
        {
            return SCREEN_WIDTH;
        }else
        {
            return SCREEN_HEIGHT;
        }
    }
    return 0;
}

@end
